﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Bamuca.Master" AutoEventWireup="true"
    CodeBehind="../Views/CadastrarGrupos.aspx.cs" Inherits="Bamuca.CadastrarGrupos" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="titulo" style="line-height: 22px; padding: 2px;">
        <center>
            <h2 style="font-family: Calibri;">
                Lista de Grupos</h2>
            <hr style="height: -12px" />
        </center>
    </div>
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <ContentTemplate>
            <div style="margin-top: 15px;">
                <center>
                    <div id="infogrp" style="width: 700px;">
                        <div id="gridgrupos" style="margin-left: 10px; float: left;">
                            <asp:GridView ID="gvGrupos" runat="server" CellPadding="4" CellSpacing="5" AutoGenerateColumns="false"
                                AllowPaging="True" PageSize="10" OnPageIndexChanging="gvGrupos_PageIndexChanging"
                                OnSelectedIndexChanged="gvGrupos_SelectedIndexChanged" EnableSortingAndPagingCallbacks="True"
                                Width="400px">
                                <AlternatingRowStyle BackColor="#99CCFF" />
                                <Columns>
                                    <asp:BoundField DataField="idgrupo" HeaderText="idgrupo" Visible="false" ItemStyle-CssClass="colunaID"
                                        HeaderStyle-CssClass="colunaID">
                                        <HeaderStyle CssClass="colunaID" />
                                        <ItemStyle CssClass="colunaID" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="nome" HeaderText="Nome" HeaderStyle-CssClass="nomeGrupo"
                                        ItemStyle-CssClass="nomeGrupo">
                                        <HeaderStyle CssClass="nomeGrupo" />
                                        <ItemStyle CssClass="nomeGrupo" />
                                    </asp:BoundField>
                                    <asp:BoundField DataField="nomestatus" HeaderText="Status" HeaderStyle-CssClass="status"
                                        ItemStyle-CssClass="status">
                                        <HeaderStyle CssClass="status" />
                                        <ItemStyle CssClass="status" />
                                    </asp:BoundField>
                                    <asp:CommandField ButtonType="Image" SelectImageUrl="~/Imagens/btn_editarmini.png"
                                        ShowSelectButton="True" />
                                </Columns>
                                <EditRowStyle HorizontalAlign="Left" />
                                <HeaderStyle BackColor="#3366FF" ForeColor="White" HorizontalAlign="Left" 
                                    VerticalAlign="Middle" />
                                <PagerStyle BackColor="#CCCCFF" />
                                <RowStyle HorizontalAlign="Left" VerticalAlign="Middle" />
                            </asp:GridView>
                        </div>
                        <div id="filtro" style="margin-left: 40px; padding: 4px; border: 1px solid #CCC;
                            float: right;">
                            <p align="left">
                                Filtro</p>
                            <p align="left">
                                <strong>Nome:</strong><br />
                                <asp:TextBox ID="tbFiltroNome" runat="server" Width="160px"></asp:TextBox>
                                <br />
                                <p align="left">
                                    <table align="left">
                                        <tr>
                                            <td>
                                                <strong>Status:</strong>
                                            </td>
                                            <td>
                                                <strong>Ordenar Por:</strong>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td align="left">
                                                <asp:RadioButtonList ID="rbListStatus" runat="server">
                                                    <asp:ListItem Selected="True" Value="2">Todos</asp:ListItem>
                                                    <asp:ListItem Value="1">Ativos</asp:ListItem>
                                                    <asp:ListItem Value="0">Inativos</asp:ListItem>
                                                </asp:RadioButtonList>
                                            </td>
                                            <td align="left">
                                                <asp:RadioButtonList ID="rbListOrdenar" runat="server">
                                                    <asp:ListItem Selected="True" Value="1">Nome</asp:ListItem>
                                                    <asp:ListItem Value="2">Status</asp:ListItem>
                                                </asp:RadioButtonList>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td align="left">
                                                &nbsp;</td>
                                            <td align="left">
                                                &nbsp;</td>
                                        </tr>
                                        <tr>
                                            <td>
                                                <asp:Button ID="btFiltrar" runat="server" Text="Filtrar" OnClick="btFiltrar_Click" />
                                            </td>
                                            <td>
                                                <asp:Button ID="btnNew" runat="server" PostBackUrl="~/Views/EditarGrupos.aspx" Text="Novo" />
                                            </td>
                                        </tr>
                                    </table>
                                </p>
                                <br />
                                <br />                                
                        </div>
                    </div>
                </center>
                <div style="clear: both; height: 1px;">
                </div>
            </div>
            </strong>
        </ContentTemplate>
    </asp:UpdatePanel>
</asp:Content>
